package com.smart.sso.server.model;

import com.smart.mvc.model.PersistentObject;

public class NodeDB extends PersistentObject{

	private static final long serialVersionUID = -4248942889541614409L;
	private final String driver = "com.mysql.jdbc.Driver" ;
	private String name;
	private String dbName;
	private String ip = "localhost";
	private String adminName;
	private String password;
	
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	public String getIp() {
		return ip;
	}
	public void setIp(String ip) {
		this.ip = ip;
	}
	public String getAdminName() {
		return adminName;
	}
	public void setAdminName(String adminname) {
		this.adminName = adminname;
	}
	public String getPassword() {
		return password;
	}
	public void setPassword(String password) {
		this.password = password;
	}
	
	public String getDbName() {
		return dbName;
	}
	public void setDbName(String dbName) {
		this.dbName = dbName;
	}
	public String getDriver() {
		return driver;
	}
	
	public String getUrl() {
		return "jdbc:mysql://" + ip + ":3306/" + dbName + "?characterEncoding=utf8" ;
	}
}
